﻿using Newtonsoft.Json;
using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
using System.Threading.Tasks;
using WLYT.Domain.Entries;

namespace WLYT.Domain.Model
{
    public class LoginResult
    {
        public bool Success { get; set; }

        public string Message { get; set; } = string.Empty;

        public Data? Data { get; set; }
    }

    public class Data
    {
        public Permission[] Permissions { get; set; }
        public Sys_User? User { get; set; }
        public string Token { get; set; } = string.Empty;
        public DateTime ExpireAt { get; set; }
    }

    public class Permission
    {
        [JsonProperty("id")]
        public string Id { get; set; } = string.Empty;
        [JsonProperty("operation")]
        public string[] Operation { get; set; }
    }
}
